package com.ruoyi.system.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.MyCurriculumVitaeWorkProjectMapper;
import com.ruoyi.system.domain.MyCurriculumVitaeWorkProject;
import com.ruoyi.system.service.IMyCurriculumVitaeWorkProjectService;

/**
 * 我的项目Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-07-12
 */
@Service
public class MyCurriculumVitaeWorkProjectServiceImpl implements IMyCurriculumVitaeWorkProjectService 
{
    @Autowired
    private MyCurriculumVitaeWorkProjectMapper myCurriculumVitaeWorkProjectMapper;

    /**
     * 查询我的项目
     * 
     * @param id 我的项目主键
     * @return 我的项目
     */
    @Override
    public MyCurriculumVitaeWorkProject selectMyCurriculumVitaeWorkProjectById(Long id)
    {
        return myCurriculumVitaeWorkProjectMapper.selectMyCurriculumVitaeWorkProjectById(id);
    }

    /**
     * 查询我的项目列表
     * 
     * @param myCurriculumVitaeWorkProject 我的项目
     * @return 我的项目
     */
    @Override
    public List<MyCurriculumVitaeWorkProject> selectMyCurriculumVitaeWorkProjectList(MyCurriculumVitaeWorkProject myCurriculumVitaeWorkProject)
    {
        return myCurriculumVitaeWorkProjectMapper.selectMyCurriculumVitaeWorkProjectList(myCurriculumVitaeWorkProject);
    }

    /**
     * 新增我的项目
     * 
     * @param myCurriculumVitaeWorkProject 我的项目
     * @return 结果
     */
    @Override
    public int insertMyCurriculumVitaeWorkProject(MyCurriculumVitaeWorkProject myCurriculumVitaeWorkProject)
    {
        myCurriculumVitaeWorkProject.setCreateTime(DateUtils.getNowDate());
        return myCurriculumVitaeWorkProjectMapper.insertMyCurriculumVitaeWorkProject(myCurriculumVitaeWorkProject);
    }

    /**
     * 修改我的项目
     * 
     * @param myCurriculumVitaeWorkProject 我的项目
     * @return 结果
     */
    @Override
    public int updateMyCurriculumVitaeWorkProject(MyCurriculumVitaeWorkProject myCurriculumVitaeWorkProject)
    {
        myCurriculumVitaeWorkProject.setUpdateTime(DateUtils.getNowDate());
        return myCurriculumVitaeWorkProjectMapper.updateMyCurriculumVitaeWorkProject(myCurriculumVitaeWorkProject);
    }

    /**
     * 批量删除我的项目
     * 
     * @param ids 需要删除的我的项目主键
     * @return 结果
     */
    @Override
    public int deleteMyCurriculumVitaeWorkProjectByIds(Long[] ids)
    {
        return myCurriculumVitaeWorkProjectMapper.deleteMyCurriculumVitaeWorkProjectByIds(ids);
    }

    /**
     * 删除我的项目信息
     * 
     * @param id 我的项目主键
     * @return 结果
     */
    @Override
    public int deleteMyCurriculumVitaeWorkProjectById(Long id)
    {
        return myCurriculumVitaeWorkProjectMapper.deleteMyCurriculumVitaeWorkProjectById(id);
    }
}
